﻿@model CmsUserGroup
@{
    ResFile = "cms_Users";
}
<fieldset class="b-form">
    @using (Html.BeginForm(Model.IsNew ? "add" : "edit", "CmsUserGroup"))
    {
        <ol class="b-form__rows ul-reset g-clear">
            <li class="b-form__row g-clear">
                <label for="GroupName">@_("User group")</label>
                @Html.TextBoxFor(p => p.GroupName, new { @class = "text" })
                @Html.ValidationMessageFor(p => p.GroupName)
            </li>
            @if (!Model.IsNew)
            { 
            <li class="b-form__row g-clear">
                <label for="IsEnabled">@_("Enabled")</label>
                @Html.CheckBoxFor(p => p.IsEnabled)
                @Html.HiddenFor(p => p.Id)
            </li>
            }
            @(Html.UserGroupPlaceholder().ForUserGroups(PredefinedUserGroups.Developer).Template(
                    @<text>
                        <li class="b-form__row g-clear">
                            <label>@_("User group scope")</label>
                            @Html.Partial("SiteAwarePlug", Model)
                        </li>
                    </text>)
                    .AlternativeTemplate(
                    @<text>
                        <li class="b-form__row g-clear" style="display:none">                        
                            @Html.Partial("SiteAwarePlug", Model)
                        </li>
                    </text>)
                  .Render())
        
	        <li class="b-form__row g-clear">	
	    	    <input class="b-button" id="btnSave" name="btnSave" type="submit" value="@_("Save")" />
	        </li>   
        </ol>
    }	
</fieldset>